package com.aspose.cells;

import java.util.ArrayList;

/** @deprecated */
public class StyleCollection {
   private WorksheetCollection a;
   private ArrayList b = new ArrayList();

   StyleCollection(WorksheetCollection sheets) {
      this.a = sheets;
   }

   public Style getThemeStyle(int themeColorType, double tint) {
      Style var4 = new Style(this.a);
      var4.getFont().a(this.a.G().getName(), this.a.G().k());
      var4.getFont().setSize(this.a.G().getSize());
      var4.getFont().b.f(this.a.G().b);
      var4.b(16);
      var4.setPattern(1);
      var4.b(34);
      var4.b.a(4, themeColorType);
      var4.b.a(tint);
      return var4;
   }

   public Style createBuiltinStyle(int type) {
      return zbqc.a(type, this.a);
   }

   public int add() {
      int var1 = this.b.size();
      Style var2 = new Style(this.a);
      var2.a((WorksheetCollection)this.a, (int)15);
      com.aspose.cells.b.a.a.ze.a(this.b, (Object)var2);
      ++var1;
      return var1 - 1;
   }

   int a(Style var1) {
      com.aspose.cells.b.a.a.ze.a(this.b, (Object)var1);
      return this.b.size() - 1;
   }

   public Style get(int index) {
      return (Style)this.b.get(index);
   }

   public Style get(String name) {
      return this.a.B().a(name);
   }

   public int getCount() {
      return this.b.size();
   }

   void a(Style var1, boolean var2) {
      if (var2) {
         com.aspose.cells.b.a.a.ze.a(this.b, (Object)var1);
      } else {
         for(int var3 = 0; var3 < this.getCount(); ++var3) {
            if (com.aspose.cells.b.a.zv.b(this.get(var3).getName(), var1.getName())) {
               this.b.set(var3, var1);
               return;
            }
         }
      }

   }

   void a() {
      this.b.clear();
   }

   void a(StyleCollection var1) {
      for(int var2 = 0; var2 < var1.b.size(); ++var2) {
         Style var3 = (Style)var1.b.get(var2);
         Style var4 = new Style(this.a);
         var4.copy(var3);
         if (var3.getName() != null) {
            var4.a(var3.getName());
         }

         com.aspose.cells.b.a.a.ze.a(this.b, (Object)var4);
      }

   }
}
